package diagramobjects;
import java.awt.Graphics;

import program.DatabaseConnection;
import program.PaintObjects;
import utils.Point;

public class Elipse extends DiagramObject
{
	private Integer Id;
	private Point FromPoint;
	private Point ToPoint;
	private Integer Dashing;
	
	public Elipse(Point fromPoint, Point toPoint, Integer dashing)
	{
		super();
		FromPoint = fromPoint;
		ToPoint = toPoint;
		Dashing = dashing;
	}
	
	public Elipse(Integer x, Integer y)
	{
		super();
		Id = 0;
		FromPoint = new Point(x, y);
		ToPoint = new Point(x, y);
		Dashing = new Integer(10);
		
	}
	
	public Point getFromPoint()
	{
		return FromPoint;
	}
	
	public void setFromPoint(Point fromPoint)
	{
		FromPoint = fromPoint;
	}
	
	public Point getToPoint()
	{
		return ToPoint;
	}
	
	public void setToPoint(Point toPoint)
	{
		ToPoint = toPoint;
	}
	
	public Integer getDashing()
	{
		return Dashing;
	}
	
	public void setDashing(Integer dashing)
	{
		Dashing = dashing;
	}
	
	public void Draw(Graphics g, PaintObjects po) 
	{
		// TODO Auto-generated method stub
		
	}

	
	public Boolean PointCollision(Integer x, Integer y) 
	{
		// TODO Auto-generated method stub
		return true;//super.PointCollision(x, y);
	}

	
	public void Print() 
	{
		// TODO Auto-generated method stub
		//super.Print();
	}

	
	public String ToDatabase() 
	{
		// TODO Auto-generated method stub
	
		
		String toReturn = "";/*Id.toString() + "," +*/
		/*Begin.getX().toString() + "," +
		Begin.getY().toString() + "," +
		Left.getX().toString() + "," +
		Left.getY().toString() + "," +
		Right.getX().toString() + "," +
		Right.getY().toString() + "," +
		End.getX().toString() + "," +
		End.getY().toString() + "," +
		Filled.toString();
		*/
		return toReturn;
	}
	
	public void AddToDatabase()
	{
		/*DatabaseConnection.AddArrow(ToDatabase());
		ArrrowColor.AddToDatabase();*/
	}

	@Override
	public void MoveByVector(Integer vx, Integer vy)
	{
		FromPoint.MoveByVector(vx, vy);
		ToPoint.MoveByVector(vx, vy);
	}
	
	
	
}
